package com.step.scene;

import com.step.mesh.Color;
import com.step.scene.camera.Camera;
import com.step.scene.fog.Fog;
import com.step.scene.light.LightList;

public class scene {
	// 相机
	Camera camera;
	// 灯光
	LightList lights;
	// 背景色
	Color backgroundColor;
	// 雾
	Fog fog;
	/*
	ISceneListener sceneListener;
	// 精灵
	ArrayList<Sprite> children = new ArrayList<Sprite>();
	// ===========================================================
	boolean enableFog;
	boolean enableLight;
	// ===========================================================
	public Scene(ISceneListener sceneListener){
		this.sceneListener = sceneListener;
		this.lights = new LightList();
		this.fog = new Fog();
		this.enableFog = false;
		this.enableLight = true;
		this.children = new ArrayList<Sprite>();
		this.camera = new LookAtCamera();
		this.backgroundColor = new Color(0, 0, 0, 255);
	}
	
	public void reset(){
		clearChildren(this);
		children.clear();
		backgroundColor.set(0, 0, 0, 255);
		lights.clear();
		this.enableFog = false;
		this.enableLight = true;
	}
	
	public void update(GL10 gl){	
		// 雾
		renderFog(gl);
	}
	
	private void renderFog(GL10 gl){
		if(enableFog){
			fog.enable(gl);
		}
		else{
			fog.disable(gl);
		}
	}
	
	private void renderLight(GL10 gl){
		
	}
	*/
}
